﻿@{
    ViewBag.Title = "送货单列表";
    Layout = "~/Views/Shared/_LayoutList.cshtml"; 
}
@(  
 Html.nbGridFor<DishDelivery>(s =>
 {
     s.Action("List");
     s.Columns(col =>
     {
         col.Bind(e => e.Id).IsKey();
         col.BindDateTime(e => e.Date).Width(70).AsSearch();
         col.BindEnum(e => e.SiteID, "ProjectSite").Width(80).AsSearch();
         col.Bind(e => e.SiteName).Hide();
         col.Bind(e => e.Address).Width(140).Align(GridAlign.Left).AsQuery().AsSearch();
         col.BindEnum(e => e.State, "DishState").Width(40);
         col.Bind(e => e.UpdateUser).Width(60);
         col.BindDateTime(e => e.UpdateDate).Width(70);
         col.BindTemplate(180)
             .Template(Url.GridRowEditLink("编辑送货单"))
             .Template(Url.GridRowDeleteLink("Date"))
             .Template(@<a href="@Url.AajxTodo(Url.Action("MaterialDelivery", new { Id = "${Id}" }), "您确认需要向项目点（${SiteName}）送货?")" class="imgbtn2" ><span
                 class="accept">送货</span></a>);
     });
     s.Buttons(btn =>
     {
         btn.BindAddButton("新建送货单");
     });
 }))
